<template>
  <div class="about">
    <!-- <keep-alive>
      <component :is="isShow?news:music"></component>
    </keep-alive> -->
    <div v-for="(item,index) of result" :key="index">
      <img class="pic" v-lazy="item.coverImgUrl">
    </div>
  </div>
</template>
<script>
import axios from 'axios'
import News from '../components/News'
import Music from '../components/Music'
export default {
  data() {
    return {
      isShow:true,
      news:News,
      music:Music,
      result:[]
    }
  },
  mounted() {
    axios.get('http://www.chengbenchao.top:3000/top/playlist?cat=%E5%8D%8E%E8%AF%AD').then(res=>{
      console.log(res.data.playlists)
      this.result = res.data.playlists
    })
  },
}
</script>

<style scoped>
.pic{
  width: 100px;
}
</style>
